package com.sxhuayuan.parking.dao;

import org.springframework.data.jpa.repository.Query;

import com.sxhuayuan.parking.entity.OemConfig;

public interface OemConfigDao extends BaseDao<OemConfig, Long> {

	@Query(value = "select a.oemConfig from Agent a where id=?1")
	OemConfig findByAgentId(Long agentId);
	
	@Query(value = "select lot.agent.oemConfig from ParkingLot lot where lot.id=?1")
	OemConfig findByParkingLotId(Long parkingLotId);
	
	OemConfig findByWxMchid(String mchid);
}
